package com.ctshk.sapp.localfun.controller;

import com.ctshk.common.annotations.OperationLogAnnotation;
import com.ctshk.common.enums.OperationLogModel;
import com.ctshk.common.enums.OperationLogType;
import com.ctshk.common.web.support.BaseController;
import com.ctshk.rpc.localfun.dto.LocalFunProductCostDTO;
import com.ctshk.rpc.localfun.req.LocalFunProductCostReq;
import com.ctshk.rpc.localfun.service.ILocalFunCostPriceService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Description
 * @Author wansi <gaylen15527491065@yeah.net>
 * @Date 2021/3/26
 */
@Api(value = "当地玩乐-成本价",tags = "当地玩乐-产品中心")
@RestController
@RequestMapping("/cost-price")
public class LocalFunCostPriceController extends BaseController {

    @DubboReference
    private ILocalFunCostPriceService iLocalFunCostPriceService;

    @ApiOperation(value="查询产品加幅成本价", notes="查询产品加幅成本价",tags = "当地玩乐-产品中心")
    @OperationLogAnnotation(operModul = OperationLogModel.TICKET, operType = OperationLogType.QUERY, operTitle = "当地玩乐-产品中心", operDesc = "查询产品加幅成本价")
    @PostMapping("/after-increase-fee")
    public List<LocalFunProductCostDTO> getProductCostList(@RequestBody LocalFunProductCostReq localFunProductCostReq){
        return iLocalFunCostPriceService.getProductCostList(localFunProductCostReq);
    }

}
